package com.yipinhouse.reception.client;

import com.yipinhouse.common.result.Result;
import com.yipinhouse.signing.client.result.ContractResult;
import com.yipinhouse.signing.client.result.HouseTradeResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import java.util.List;


@FeignClient(contextId = "signingWebClient", name = "reception", path = "reception")
public interface SigningWebQueryClient {

    /**
     * 通过用户id获取房屋交易记录
     * @return
     */
    @GetMapping("/getHouseTradeByUser")
    Result<List<HouseTradeResult>> getHouseTradeByUser();

    /**
     * 通过id查询房屋交易记录
     * @param houseTradeId
     * @return
     */
    @GetMapping("/getHouseTradeById")
    Result<HouseTradeResult> getHouseTradeById(@RequestParam("houseTradeId") Integer houseTradeId);

    /**
     * 根据用户ID查询合同
     * @return
     */
    @GetMapping("/getContractByUser")
    Result<List<ContractResult>> getContractByUser();
}
